﻿/*
Copyright (c) 2010 Lance Ward
This software is licensed under the MIT license, except where otherwise noted.
For complete license details, refer to license.txt
*/

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;
using System.Drawing;

namespace ADNLib
{
    [Serializable]
	public class PathPoint
	{
		private PointF point = new PointF();
		private PointF controlA = new PointF();
		private PointF controlB = new PointF();

		public PathPoint() { }
		public PathPoint(PointF point)  //initialized with the same point for all
		{
			this.point = point;
			controlA = point;
			controlB = point;
		}

        public PathPoint(PointF point, PointF controlA, PointF controlB)
        {
            this.point = point;
            this.controlA = controlA;
            this.controlB = controlB;
        }

		[XmlElement]
		public PointF Point
		{
			get{return point;}
			set{point = value;}
		}

		[XmlElement]
		public PointF ControlA
		{
			get
			{
				return controlA;
			}
			set
			{
				controlA = value;
			}
		}

		[XmlElement]
		public PointF ControlB
		{
			get
			{
				return controlB;
			}
			set
			{
				controlB = value;
			}
		}
	}
}
